package org.xdq.反射机制;

public class Test2 {

    public static void main(String[] args) throws InstantiationException, IllegalAccessException {
        Student stu = new Student();
        stu.setStuId("001");
        stu.setStuName("学生1");
        stu.setStuScore(99);

//        A a = new A();
//
//        Utils.copy(stu, a);

//        Object obj = Utils.copy(stu, A.class);
//        A a = (A)obj;

        A a = Utils.copy(stu,A.class);

        System.out.println(a.getAid()+","+a.getStuName()+","+a.getStuScore());
    }
}
